The present invention is related to computer networks and, more particularly, to a performance accelerator providing file caching and other techniques to accelerate network computers.
A large portion of the tremendous increase in performance seen in the microprocessor world over the last fifteen years can be attributed to better management of the microprocessor memory hierarchy. In particular, the technique known as caching alone is responsible for a large part of the performance improvement. In a common memory cache, recently accessed data from the relatively slow main memory of dynamic random access memory (DRAM) is stored in a cache of relatively fast static random access memory (SRAM). Performance increases are achieved when requested data is retrieved from the cache instead of the main memory.
Another form of caching involves storing recently accessed data from hard disks in main memory. Because the access speed of main memory is significantly faster than a hard disk access, disk caching provides substantial performance increases. A common disk caching program is SmartDrive that is included in Microsoft Windows.
In the late 1980's, network designers also realized the benefits of caching and began to apply some of these techniques to this new domain in the form of network caching. Networks typically include a distributed file system which allows multiple computer systems to share data or files. The computer system that stores a file locally is called the server with client computer systems making requests to the server to remotely access the file. In network caching, a client computer system stores network data or files locally on a hard disk. Distributed file systems like AFS and CODA (both developed at Carnegie-Mellon University), Sprite (developed at the University of California, Berkeley), and several others include some form of network caching to produce better performing and more robust distributed file systems.
FIG. 1 illustrates a common microprocessor and data storage hierarchy. A central processing unit (CPU) 10 performs the operations of the computer using data stored in one of the storage media shown below the CPU. The storage media include a cache 12, main memory 14, hard disk 16, and network 18. The cache is a form of high speed memory that provides the quickest access time. Access times steadily decrease to the network which typically provides the slowest access time. A memory cache 20 involves storing data from the main memory in the cache. Similarly, a disk cache 22 (e.g., SmartDrive) involves storing data from the disk in main memory. Lastly, a network cache 24 involves storing data from the network on the hard disk.
The present invention is directed generally to improving network caching capabilities in computer networks. However, the above description does not imply that the different forms of caching operate individually. To the contrary, the different forms of caching typically operate together. For example, a file on the network may be cached on a local hard disk that is disk cached in main memory.
The fundamental idea behind caching, in both the memory, hard disk, and network worlds, is to keep a copy of recently accessed data in a faster storage area (the "cache") so that subsequent accesses to the same data proceed at a faster rate. Caching in a distributed file system involves having the client computer system store locally a copy of the data or file that resides on the server. The concept of locality of reference states that there is a high probability that data will be reused soon after its first use. By obtaining a local copy of the data or file, a client computer system can avoid many further interactions with the server.
References within a file typically exhibit spatial locality meaning that if a block of a file is read, there is high probability that succeeding blocks will also be read. A client computer system can take advantage of spatial locality by caching the entire file or by requesting successive blocks of a file while a block is being processed. By taking advantage of both locality of reference and spatial locality, caching results in much faster overall performance for the client computer system.
However, prior art cache systems for distributed file systems are inherently a part of the server operating system. For example, AFS, CODA, and Sprite are all "built" or "compiled" into the UNIX kernel. Thus, to obtain the benefits of these systems, one needs to install the entire operating system on at least the server side and generally also on the client side of the distributed file system. However, installing a new operating on both the client and server sides is not generally feasible in a commercial setting because the process is very time consuming and existing applications may be incompatible with the new operating system.
Prior art cache systems are built into the operating system for a number of reasons including the following:
(a) It is difficult to maintain cache coherency between the client and server computer systems if the cache system is not a part of the server operating system. This is because the server needs to let the client know what data has been modified to maintain cache coherency, but if the cache system is not a part of the operating system, the operating system generally does not know data has been modified. PA1 (b) The cache system is such an integral part of the file system (which is part of the operating system) that it is much easier to design them in conjunction. PA1 (c) The programmers working on cached distributed file systems have typically been in academic rather than commercial environments, where they have had full access to the source code of the operating system and thus have no reservations about modifying the source code to suit their needs.
What is needed is a performance accelerator that provides file caching for distributed file systems without requiring modification of the server distributed file system or operating system. The present invention fulfills this and other needs.